home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Borland / Borland C++ V5.02 / SUPERPD.PAK / PADITEM.H < prev    next >
C/C++ Source or Header  |  1997-05-06  |  1KB  |  47 lines

  1. // paditem.h : interface of the CEmbeddedItem class
  2. //
  3. // This is a part of the Microsoft Foundation Classes C++ library.
  4. // Copyright (C) 1992-1995 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Microsoft Foundation Classes Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Microsoft Foundation Classes product.
  12.  
  13.  
  14. #ifndef __PADITEM_H__
  15. #define __PADITEM_H__
  16.  
  17. class CPadDoc;
  18. class CPadView;
  19.  
  20. class CEmbeddedItem : public COleServerItem
  21. {
  22.     DECLARE_DYNAMIC(CEmbeddedItem)
  23.  
  24. // Constructors
  25. public:
  26.     CEmbeddedItem(CPadDoc* pContainerDoc);
  27.  
  28. // Attributes
  29.     UINT m_nBeg, m_nEnd;
  30.     CPadDoc* GetDocument() const
  31.         { return (CPadDoc*) COleServerItem::GetDocument(); }
  32.     CPadView* GetView() const;
  33.  
  34. // Implementation
  35. public:
  36.     virtual BOOL OnDraw(CDC* pDC, CSize& rSize);
  37.     virtual BOOL OnGetExtent(DVASPECT dwDrawAspect, CSize& rSize);
  38.  
  39. protected:
  40.     virtual BOOL OnRenderFileData(LPFORMATETC lpFormatEtc, CFile* pFile);
  41.     virtual void Serialize(CArchive& ar);   // overridden for document i/o
  42.  
  43.     void SaveToFile(CFile* pFile);
  44. };
  45.  
  46. #endif  // __PADITEM_H__
  47.